<script setup>
const username = useCookie("username");
if (!username.value) {
	await navigateTo("/login")
}
definePageMeta({
	layout: "default",
})
</script>
<template>
	<div class="flex flex-col gap-2 py-2 px-2">
		<NuxtLink to="/">
			<UButton>Главная</UButton>
		</NuxtLink>
		<NuxtLink to="/login">
			<UButton>Авторизация</UButton>
		</NuxtLink>
		<NuxtLink to="/logout">
			<UButton>Выход</UButton>
		</NuxtLink>
	</div>
</template>